package net.myspring.rabbit.receiver;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.amqp.rabbit.annotation.RabbitListeners;
import org.springframework.stereotype.Component;

/**
 * @author wangzm
 */
@Component
public class TopicReceiverController {

    @RabbitHandler
    @RabbitListener(queues = "topic.message")
    public void message(String hello) {
        System.out.println("topic.message123 : " + hello);
    }

    @RabbitHandler
    @RabbitListener(queues = "topic.messages")
    public void messages(String hello) {
        System.out.println("topic.messagesssssssssss : " + hello);
    }
}
